function Maxz_LoadImg(w,h){
document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" id="object_flash_player" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0"  width="'+w+'" height="'+h+'"><param name="movie" value="/fileUpload/flashPic/js/pic.swf"><param name="quality" value="high"><param name="allowScriptAccess" value="always"><param name="wmode" value="transparent"><param name="allowFullScreen" value="true"><param name="FlashVars" value="bcastr_xml_url=/fileUpload/flashPic/js/pic.xml"><embed src="/fileUpload/flashPic/js/pic.swf" flashvars="bcastr_xml_url=/fileUpload/flashPic/js/pic.xml" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" allowfullscreen="true" width="'+w+'" height="'+h+'"></object>');
}

//主站自动播放图片
function homeSite_LoadImg(w,h)
{
   document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" id="object_flash_player" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0"  width="'+w+'" height="'+h+'"><param name="movie" value="/fileUpload/flashPic/js/pic.swf"><param name="quality" value="high"><param name="allowScriptAccess" value="always"><param name="wmode" value="transparent"><param name="allowFullScreen" value="true"><param name="FlashVars" value="bcastr_xml_url=/fileUpload/flashPic/js/homeSite_pic.xml"><embed src="/fileUpload/flashPic/js/pic.swf" flashvars="bcastr_xml_url=/fileUpload/flashPic/js/homeSite_pic.xml" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" allowfullscreen="true" width="'+w+'" height="'+h+'"></object>');
}

function selectTag(showContent,selfObj){
var tag = document.getElementById("tags").getElementsByTagName("li");
var taglength = tag.length;
for(i=0; i<taglength; i++){
tag[i].className = "";
}
selfObj.parentNode.className = "selectTag";
for(i=0; j=document.getElementById("tagContent"+i); i++){
j.style.display = "none";
}
document.getElementById(showContent).style.display = "block";
}


 // 加载xml文档
     var xmlFile;
	function  loadXML(xmlFile)
	{
	    var xmlDoc;
	    if(window.ActiveXObject)
	    {
	        xmlDoc    = new ActiveXObject('Microsoft.XMLDOM');
	        xmlDoc.async    = false;
	        xmlDoc.load(xmlFile);
	        //alert('ms:'+xmlFile);
	        //alert(xmlDoc);
	    }
	    else if (document.implementation && document.implementation.createDocument)
	    {
	        xmlDoc    = document.implementation.createDocument('', '', null);
	        xmlDoc.load(xmlFile);
	        //alert('ff:'+xmlFile);
	    }
	    else
	    {
	        return null;
	    }
	    
	    return xmlDoc;
	}
	
	// 首先对xml对象进行判断
	checkXMLDocObj    = function(xmlFile)
	{
	    var xmlDoc    = loadXML(xmlFile);
	    //alert(xmlDoc);
	    if(xmlDoc==null)
	    {
	        alert('您的浏览器不支持xml文件读取,于是本页面禁止您的操作,推荐使用IE5.0以上可以解决此问题!');
	        window.location.href='/index.jsp';
	    }
	    
	    return xmlDoc;
	}
	
	// 然后开始获取需要的Login/Weapon/W的第一个节点的属性值
	//var xmlDoc    = checkXMLDocObj('/fileUpload/flashPic/js/homeSite_pic.xml');
	//var v    = xmlDoc.getElementsByTagName('bcaster/item')[0].childNodes.getAttribute('titleName')
	var focus_width=478;
	var focus_height=205;
	var text_height=20;
	var swf_height = focus_height+text_height;

	var pics = '';
	var links = '';
	var texts = '';
	var xPath='';
	var mywidth=0;
	var myheight=0;
	
	display  = function(xPath,mywidth,myheight)
	{
	    if(mywidth!=0 && mywidth!='')
	    {
	      focus_width = mywidth;
	    }
	    
	    if(myheight!=0 && myheight!='')
	    {
	      focus_height = myheight;
	    }
	  
	    var xmlDoc    = loadXML(xPath);
	    //alert(xmlDoc.getElementsByTagName('bcaster/item')[3].getAttribute('titleName'));
	    var li=xmlDoc.getElementsByTagName('bcaster/item');
	    for(var dd=0;dd<li.length;dd++)
	    {
	       if(dd==0)
	       {
	        pics ='';
	        links = '';
	        texts = '';
	         pics = escape(li[dd].getAttribute('item_url'));
	         links = escape(li[dd].getAttribute('link'));
	         texts =  li[dd].getAttribute('titleName');
	         
	         
	       }
	       else
	       {
	         pics =pics +"|"+ escape(li[dd].getAttribute('item_url'));
	         links = links +"|"+ escape(li[dd].getAttribute('link'));
	         texts = texts +"|"+ li[dd].getAttribute('titleName');
	       }
	    }
	  document.write('<embed src="/fileUpload/flashPic/js/pixviewer.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#F4FAFB" quality="high" width="'+ focus_width +'" height="'+ swf_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash"/>');
	}
	